/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ru.ibrae.excelparser1.excelstorageentities.entities;

import java.util.Date;

/**
 *
 * @author murr
 */
public class CommonInfo {
    //~ Instance fields --------------------------------------------------------

    private Date beginning;
    private Date end;
    private Date creationDate;
    private Integer rowCount;
    private OrganizationInfo organizationInfo;

    //~ Constructors -----------------------------------------------------------
    public CommonInfo(Date beginning, Date end, Date creationDate,
            String okato, String ogrn, String shortName,
            String fullName, Integer rowCount) {
        this.beginning = beginning;
        this.end = end;
        this.creationDate = creationDate;
        organizationInfo = new OrganizationInfo(okato, ogrn, shortName, fullName);
        this.rowCount = rowCount;
    }

    public CommonInfo(Date beginning, Date end, Integer rowCount,
            OrganizationInfo organizationInfo) {
        this.beginning = beginning;
        this.end = end;
        this.rowCount = rowCount;
        this.organizationInfo = organizationInfo;
    }

    //~ Methods ----------------------------------------------------------------
    public Date getBeginning() {
        return beginning;
    }

    public Date getCreationDate() {
        return creationDate;
    }

    public Date getEnd() {
        return end;
    }

    public Integer getRowCount() {
        return rowCount;
    }

    public void setShortName(String shortName) {
        organizationInfo.setShortName(shortName);
    }

    public void setOkato(String okato) {
        organizationInfo.setOkato(okato);
    }

    public void setOgrn(String ogrn) {
        organizationInfo.setOgrn(ogrn);
    }

    public void setFullName(String fullName) {
        organizationInfo.setFullName(fullName);
    }

    public String getShortName() {
        return organizationInfo.getShortName();
    }

    public String getOkato() {
        return organizationInfo.getOkato();
    }

    public String getOgrn() {
        return organizationInfo.getOgrn();
    }

    public String getFullName() {
        return organizationInfo.getFullName();
    }

    public OrganizationInfo getOrganizationInfo() {
        return organizationInfo;
    }

    public void setOrganizationInfo(OrganizationInfo organizationInfo) {
        this.organizationInfo = organizationInfo;
    }
}
